package service.Impl;

import dao.EmployeeChangeDao;
import dao.Impl.EmployeeChangeDaoImp;
import entity.EmployeeChange;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import service.EmployeeChangeService;

import java.util.List;

/**
 * 员工变更记录服务实现类
 */
@Service
@Transactional
public class EmployeeChangeServiceImpl implements EmployeeChangeService {
@Autowired
private EmployeeChangeDaoImp employeeChangeDaoImp;

    @Override
    public Boolean create(EmployeeChange employeeChange) {
        return employeeChangeDaoImp.create(employeeChange);
    }

    @Override
    public List<EmployeeChange> findAll() {
        return employeeChangeDaoImp.findAll();
    }

    @Override
    public EmployeeChange findById(Long id) {
        return employeeChangeDaoImp.findById(id);
    }

    @Override
    public Boolean update(EmployeeChange employeeChange) {
       return employeeChangeDaoImp.update(employeeChange);
    }

    @Override
    public Boolean deleteById(Long id) {
      return employeeChangeDaoImp.deleteById(id);
    }


}
